# - Try to find SDL2pp library
#
# Once done this will define
#
#  SDL2PP_FOUND
#  SDL2PP_INCLUDE_DIRS
#  SDL2PP_LIBRARIES

IF(SDL2PP_INCLUDE_DIR AND SDL2PP_LIBRARY)
	# in cache already
	SET(SDL2PP_FIND_QUIETLY TRUE)
ENDIF(SDL2PP_INCLUDE_DIR AND SDL2PP_LIBRARY)

FIND_PATH(SDL2PP_INCLUDE_DIR SDL2pp/SDL2pp.hh HINTS "@CMAKE_INSTALL_PREFIX@/include")

FIND_LIBRARY(SDL2PP_LIBRARY NAMES SDL2pp HINTS "@CMAKE_INSTALL_PREFIX@/lib")

MARK_AS_ADVANCED(SDL2PP_INCLUDE_DIR SDL2PP_LIBRARY)

INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(SDL2PP
	REQUIRED_VARS SDL2PP_INCLUDE_DIR SDL2PP_LIBRARY
)

IF(SDL2PP_FOUND)
	SET(SDL2PP_INCLUDE_DIRS ${SDL2PP_INCLUDE_DIR} @SDL2_ALL_INCLUDE_DIRS_STR@)
	SET(SDL2PP_LIBRARIES @SDL2PP_EXTRA_LIBRARIES_STR@ ${SDL2PP_LIBRARY} @SDL2_ALL_LIBRARIES_STR@)
ENDIF(SDL2PP_FOUND)
